<?php 
	include 'db.php';
	$itemId = $_POST['targetItem'];
	$isActive = $_POST['isActive'];
	$magDesc = $_POST['magDesc'];
	$phCode = $_POST['phCode'];
	$itemName = $_POST['itemName'];
	$itemDesc = $_POST['itemDesc'];
	$itemPrice = $_POST['itemPrice'];
	$wattage = $_POST['watts'];
	$halogenWatt = $_POST['chw'];
	$socket = $_POST['socket'];
	$beamInt = $_POST['binsten'];
	$beamAngle = $_POST['bangle'];
	$lifetime = $_POST['lifetime'];
	$dimmable = $_POST['dimmable'];
	$lumenOutput = $_POST['lumout'];
	$efficacy = $_POST['effi'];
	$unitsPerPack = $_POST['upp'];
	$colorRendering = $_POST['cri'];
	$colorTemp = $_POST['colorTemp'];
	$NC = $_POST['nc'];
	
	
	$sql = "UPDATE items SET isActive='$isActive', magDesc='$magDesc', phCode='$phCode',itemName='$itemName', itemDesc='$itemDesc', itemPrice='$itemPrice', wattage='$wattage', halogenWatt='$halogenWatt', socket='$socket', beamInt='$beamInt', beamAngle='$beamAngle', lifetime='$lifetime', dimmable='$dimmable', lumenOutput='$lumenOutput', efficacy='$efficacy', unitsPerPack='$unitsPerPack', colorRendering='$colorRendering', colorTemp='$colorTemp', NC='$NC' WHERE itemId='$itemId'";
	
	@mysql_query($sql);	
	header("Location: adminpage.php?view=1&stat=upsuccess");	

?>